﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Net.Sockets;
using System.Net;

namespace Mighty.PlayingBoard
{
    public class Client
    {
        public String id;
        public Socket socket;

        public Client(String c_id, Socket c_socket)
        {
            id = c_id;
            socket = c_socket;
        }

        public String GetIP()
        {
            IPEndPoint ip = (IPEndPoint)socket.RemoteEndPoint;
            return ip.Address.ToString();
        }

        public int GetPort()
        {
            IPEndPoint ip = (IPEndPoint)socket.RemoteEndPoint;
            return ip.Port;
        }
    }
}
